import http from '/@/utils/request'
const base = "product/cate/";

export function getProductCateList(data) {
    return http.request({
        method: 'get',
        url: base + 'list',
        data
    })
}
export function getProductCateSelectList() {
    return http.request({
        method: 'get',
        url: base + 'list.select',
    })
}
/**
 * 新增商品分类信息
 */
export const addProductCate = (data) => {
    return http.request({
        url: '/product/cate/add',
        method: 'post',
        data
    })
}

/**
 * 查询商品分类信息列表
 */
export const listProductCate = (query) => {
    return http.request({
        url: '/product/cate/list',
        method:'get',
        params:query
    })
}

/**
 * 修改商品信息
 */
export const updateProductCate = (data) => {
    return http.request({
        url: '/product/cate/update',
        method: 'put',
        data
    })
}

/**
 * 删除商品信息
 */
export const delProductCate = (data) => {
    return http.request({
        url: '/product/cate/delete' ,
        method: 'put',
        data
    })
}

/**
 * 查询商品分类下拉列表
 */
export const listProductCateSelect = () => {
    return http.request({
        url: '/product/cate/list.select',
        method:'get'
    })
}
